@extends('layouts.app')

@section('content')
<div class="container">
  <div class="col-md-10 offset-md-1">
    <div class="card ">
      <div class="card-header">
        <h1>
          Pictuer
          <a class="btn btn-success float-xs-right" href="{{ route('pictuers.create') }}">Create</a>
        </h1>
      </div>

      <div class="card-body">
        @if($pictuers->count())
              @foreach($pictuers as $pictuer)
                @if(count($pictuer->tags) > 0)
                    @foreach($pictuer->tags as $tag)
                        {{$tag->name}}
                    @endforeach
                @endif
              @endforeach
          {!! $pictuers->render() !!}
        @else
          <h3 class="text-xs-center alert alert-info">Empty!</h3>
        @endif
      </div>
    </div>
  </div>
</div>

@endsection
